Error: Illegal file name "'+imgparts[0]+'"; must match "\w[\w-]*\.*[\w-]*"